/**
 * New node file
 */

// 모듈을 추출합니다.
var connect = require('connect');



//서버를 생성합니다.
var server = connect.createServer(connect.router(function(app) {
	
	// GET - /Home/Index
	app.get('/Home/Index', function(req,res,next) {
		res.writeHead(200,{'Content-Type':'text/html'});
		res.write('<h1>Index Page</h1>');
		res.end();
	});
	
	app.get('/Home/About', function(req,res,next) {
		res.writeHead(200,{'Content-Type':'text/html'});
		res.write('<h1>About Page</h1>');
		res.end();
	});
	
	app.get('/Product/:id', function(req,res,next) {
		res.writeHead(200,{'Content-Type':'text/html'});
		res.write('<h1>Product page - ' + req.params.id + '</h1>');
		res.end();
	});
	
	
	
})).listen(52273,function() {
	console.log('Server Running at http://127.0.0.1:52273');
});

